package cn.codergege.demo.mock

import org.springframework.stereotype.Component

@Component
class Publisher {
    List<Subscriber> subscribers = []
    void send(String messages) {
        subscribers*.receive(messages)
    }
}
